<template>
    <div>
    <h1>这是Home页面</h1>
    <el-button type="primary" @click="testAxios()">axios</el-button>
    </div>
</template>

<script>
    import Axios from 'axios'
    export default {
        name: "Home",
        methods:{
            testAxios(){
                Axios.get('http://localhost:8000')
                .then(function (res) {
                        alert(res.data);
                }).catch(function (res) {
                        alert(res);
                });
            }
        }
    }
</script>

<style scoped>

</style>